package pattern15.company;

/**
 * 财务部叶子节点
 * @author wdl
 */
public class FinanceDepartment extends BaseCompany{
    public FinanceDepartment(String name) {
        super(name);
    }

    @Override
    public void add(BaseCompany company) {

    }

    @Override
    public void remove(BaseCompany company) {

    }

    @Override
    public void display(int depth) {
        for (int i=0;i<depth;i++){
            System.out.print("-");
        }
        System.out.println(name);
    }

    @Override
    public void lineOfDuty() {
        System.out.println(name+"公司财务收支管理");
    }
}
